package com.piece.module.generator.repository.impl;

import com.piece.core.jpa.repository.BaseRepository;
import com.piece.module.generator.model.GenTableColumn;
import com.piece.module.generator.repository.GenTableColumnRepository;
import org.springframework.stereotype.Repository;
import java.util.List;

@Repository
public class GenTableColumnRepositoryImpl extends BaseRepository<GenTableColumn, String> implements GenTableColumnRepository {

    @Override
    public List<GenTableColumn> findColumnsByTableId(long tableId) {
        String hql = "from GenTableColumn where tableId = ?";
        return this.find(hql, new Object[]{ tableId});
    }
}
